package cn.cloud.all.security.authentication;

import javax.servlet.http.HttpServletRequest;

/**
 * Implementation of {@link AuthenticationDetailsSource} which builds the details object
 * from an <tt>HttpServletRequest</tt> object, creating a {@code WebAuthenticationDetails}
 */
public class WebAuthenticationDetailsSource implements AuthenticationDetailsSource<HttpServletRequest, WebAuthenticationDetails> {

    public WebAuthenticationDetails buildDetails(HttpServletRequest context) {
        return new WebAuthenticationDetails(context);
    }
}
